<?php

namespace common\models\mongo;

/**
 * 用于统计用户新消息数目
 * @package common\models\mongo
 */
class DynamicMessCount extends BaseMongo {

    use \common\traits\TimestampBehavior;

    protected $timeStamp = 'cud';
    protected $softDel = true;

    public function rules() {
        return [
            [['user_id'], 'required'],
            [['mess_cnt'], 'required'],
            [['created_at', 'updated_at', 'deleted_at'], 'integer'],
        ];
    }

    public function attributesInit() {
        return [
            'user_id',
            'mess_cnt',
            'created_at',
            'updated_at',
        ];
    }
}